import { defineStore } from "pinia";
import { Names } from "../../store-namespace";
import { _get, _post, _put, _delete, http } from "@/utils/axios";
import { ElNotification } from "element-plus"; //处理导航信息
import { ServiceMProject } from "@/api/backend/index";
import { mapCompanies } from "@/utils/common";

export const useProject = defineStore(Names.Project, {
  state: () => {
    return {};
  },
  getters: {},
  actions: {
    //获取服务项目列表数据
    getProjectList(filter: any) {
      return new Promise((resolve, reject) => {
        _get(ServiceMProject + "/list", filter, "json", "").then((res) => {
          console.log("获取服务商单个数据", res);
          resolve(res);
        });
      });
    },
  },
});
